{% extends "base.html" %}

{% block content %}

{% if error_message %}<p class="error">{{ error_message }}</p>{% endif %}
{% if idea %}
<form action="/ideas/{{ idea.title }}/edit/" method="post" class="f-wrap-1">
<h3>Editing {{ idea.title }}</h3>
<label for="title"><b>Idea title:</b>
<input type="text" name="title" value="{{ idea.title }}" class="f-name"/>
</label>

<label for="idea"><b>Idea text:</b>
<textarea id="idea" name="text" class="f-comments" rows="6" cols="20">
{{ idea.text }}
</textarea>
<br />
</label>

<label for="tags"><b>Tags:</b>
<input type="text" name="tags" class="f-name" value="{{ idea.tags }}" />
</label>
<br />
<input type="submit" value="Edit" class="f-submit" /> <br />
</form>
{% endif %}
{% endblock %}